package com.smiier.skin.net;

import java.io.File;

import android.content.Context;
import cn.o.app.net.NetTask;

import com.smiier.skin.constant.Constant;
import com.smiier.skin.net.SysUploadPicTask.SysUploadPicRequest;
import com.smiier.skin.net.SysUploadPicTask.SysUploadPicResponse;
import com.smiier.skin.util.GlobalSettings;

/**
 * 上传照片
 * 
 * @author 杨文华
 * 
 */
public class SysUploadPicTask extends
		NetTask<SysUploadPicRequest, SysUploadPicResponse> {

	public static class SysUploadPicRequest extends ORequest {
		public String token;
		public File pic;
		public String appname = Constant.APP_NAME;
	}

	public static class SysUploadPicResponse extends OResponse {
		public String Res;
	}

	@Override
	public void setContext(Context context) {
		super.setContext(context);
		mUrl = GlobalSettings.SERVER_URL + GlobalSettings.SERVER_URL_JOIN
				+ "?api=SYS.UploadPic";
		mRequestMethod = METHOD_POST;
	}
}
